<?php
  print HTML::style('css/menu.css');
  print HTML::style('css/bootstrap.css');
  print HTML::style('css/general.css');
  print HTML::style('css/game.css');
  
  LoadFacebookCommentScript();
  PrintBeginContent();
  $game = new Game(null, $gameName);
  $viewsCount = $game->views;
  $game->views = $viewsCount + 1;
  $game->Save();
  $attributes = array(
    'id' => 'flashgallery-1',
    'style' => 'visibility: visible;',
    'width' => $game->width . 'px',
    'height' => $game->height . 'px',
    'type' => 'application/x-shockwave-flash',
    'data' => $game->GenerateSwfUrl()
  );
?>
<title><?php print $game->title; ?></title>
<div id="header" class="game-page">
  <?php PrintTopMenu(); ?>
  <div class="clear"></div>
</div>

<div class="clear"></div>

<div id="content">
  <div class="left">
    <object <?php print HTML::attributes($attributes)?>  ></object>
  </div>
  <div class="right">
    <h1><?php print $game->title; ?></h1>
    <?php PrintGameDescriptionBlock($game); ?>
  </div>
  <div class="clear"></div>
  <div class="fb-comments" data-href="<?php print SITE_NAME . $game->GenerateGameUrl();?>" data-width="620" data-num-posts="2"></div>
</div>

<div class="clear"></div>

<?php
  PrintFooterPage(); 
  PrintEndContent();
?>